

Pod::Spec.new do |s|
  
  s.name         = "UGBox"
  s.version      = "1.1.2"
  s.summary      = "OC常用功能"
  
  s.homepage     = "https://github.com/ubungit/UGBox"
  s.license      = "MIT"
  
  s.author             = { "ubungit" => "296019487@qq.com" }
  s.social_media_url   = "296019487@qq.com"
  
  s.source       = { :git => "https://github.com/ubungit/UGOCMagicbox.git", :tag => "#{s.version}" }
  s.ios.deployment_target     = '10.0'
  s.static_framework = true
  
  
  s.frameworks = 'AVFoundation', 'UIKit'
  
  s.default_subspec = 'all'

  s.subspec 'base' do |spec|
    
    spec.prefix_header_contents = <<-EOS
    
    #define TESTDEBUG
    
    EOS
    spec.dependency 'YYKit'
    spec.dependency 'MBProgressHUD'
    spec.dependency 'Masonry'
    spec.dependency 'BlocksKit'
    spec.dependency 'SDWebImage'
    spec.dependency 'IQKeyboardManager'
    spec.source_files  = "Base", "UGBox/OC/Base.h" ,"UGBox/OC/Category/**/*.{h,m}","UGBox/OC/Base/OC/**/*.{h,m}","UGBox/OC/Base/Swift/**/*.{swift}"
    
  end
  
  s.subspec 'common' do |spec|
    spec.dependency 'UGBox/base'
    spec.dependency  "RTRootNavigationController"
    spec.dependency 'FontAwesome+iOS'
    spec.dependency 'RZRichTextView'
    spec.source_files  = "Common", "UGBox/OC/Common/**/*.{h,m}"
    
  end
  
  s.subspec 'network' do |spec|
    spec.dependency  'AFNetworking'
    spec.source_files  = "Network", "UGBox/OC/network/**/*.{h,m}"
    
  end
  
  s.subspec 'defualCell' do |spec|
    
    spec.dependency 'UGBox/base'
    spec.dependency 'UGBox/common'
    spec.source_files  = "DefualCell", "UGBox/OC/DefualCell/**/*.{h,m}"
    
  end
  s.subspec 'copy' do |spec|
    
    spec.dependency 'UGBox/base'
    spec.dependency 'UGBox/common'
    spec.source_files  = "copy", "UGBox/OC/Copy/**/*.{h,m}"
    
  end
  
  s.subspec 'login' do |spec|
    
    spec.dependency 'UGBox/base'
    spec.dependency 'UGBox/common'
    spec.source_files  = "login", "UGBox/OC/Login/**/*.{h,m}"
    
  end
  
  s.subspec 'home' do |spec|
     
     spec.dependency 'UGBox/base'
     spec.dependency 'UGBox/common'
     spec.dependency 'UGBox/network'
     spec.source_files  = "home", "UGBox/OC/Home/**/*.{h,m}"
     
   end
  
  s.subspec 'store' do |spec|
    spec.prefix_header_contents = <<-EOS
    
    #import <BlocksKit/BlocksKit.h>
    #import <BlocksKit/BlocksKit+UIKit.h>
    #import <YYKit/YYKit.h>
    #import "UIViewController+Routes.h"
    #import <SDWebImage/SDWebImage.h>
    #import <FontAwesome_iOS/UIFont+FontAwesome.h>
    #import <FontAwesome_iOS/NSString+FontAwesome.h>
    #import <FontAwesome_iOS/UIImage+FontAwesome.h>
    #import <FontAwesome_iOS/FAImageView.h>
    
    #import "SupleViewController.h"
    #import "Network.h"
    #import "UserInfo.h"
    #import "StoreInfo.h"
    #import "NetworkConfig.h"
    
    EOS
     spec.dependency 'UGBox/base'
     spec.dependency 'UGBox/common'
     spec.dependency 'UGBox/network'
     spec.dependency 'UGBox/swift'
     
     spec.dependency 'TZImagePickerController'
     spec.source_files  = "store", "UGBox/OC/Mall/store/**/*.{h,m}"
     
   end

  s.subspec 'welcom' do |spec|
    
    spec.prefix_header_contents = <<-EOS
    #import <UGBox/Base.h>
    #import <Masonry/Masonry.h>

    EOS
    spec.pod_target_xcconfig = {
      'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1',
      'SUPPORTS_MACCATALYST' => 'YES',
      'DERIVE_MACCATALYST_PRODUCT_BUNDLE_IDENTIFIER' => 'NO'
    }
    spec.framework = 'ImageIO'
    spec.dependency 'SVGAPlayer'
    spec.dependency 'SDWebImage'
    spec.dependency 'SuperPlayer'
    spec.dependency 'UGBox/base'
    spec.source_files  = "Welcom", "UGBox/OC/Welcom/**/*.{h,m}"
  end
  
  
  
  s.subspec 'swift' do |spec|
    spec.prefix_header_contents = <<-EOS

     #import <YYKit/YYKit.h>
     #import "UIViewController+Routes.h"
     #import <SDWebImage/SDWebImage.h>
     #import <FontAwesome_iOS/UIFont+FontAwesome.h>
     #import <FontAwesome_iOS/NSString+FontAwesome.h>
     #import <FontAwesome_iOS/UIImage+FontAwesome.h>
     #import <FontAwesome_iOS/FAImageView.h>
     
     #import "SupleViewController.h"
     #import "Network.h"
     #import "UserInfo.h"
     #import "StoreInfo.h"

     EOS
     
    spec.dependency 'UGBox/base'
    spec.dependency "RTRootNavigationController"
    spec.dependency 'FontAwesome+iOS'
    spec.dependency 'SnapKit'
    spec.source_files  = "Swift", "UGBox/Swift/TabCategory/**/*.{h,m,swift}", "UGBox/Swift/UGPageCollectionView/**/*.{h,m,swift}", "UGBox/Swift/WKWebView/**/*.{h,m,swift}"
  end
  
  s.subspec 'all' do |spec|
    
    spec.prefix_header_contents = <<-EOS
    #import <UGBox/Base.h>
    #import <Masonry/Masonry.h>
    EOS
    
    spec.dependency 'UGBox/defualCell'
    spec.dependency 'UGBox/welcom'
    spec.dependency 'UGBox/common'
    spec.dependency 'UGBox/copy'
    spec.dependency 'UGBox/swift'
    spec.dependency 'UGBox/store'
    spec.dependency 'UGBox/home'
    spec.dependency 'UGBox/login'
    spec.dependency 'UGBox/network'
    spec.source_files  = "all","UGBox/UGBox.h"
  end

end
